import { requestClient } from '#/api/request';
// 获取角色列表
export const RolePage = (params: any) =>
  requestClient.get('/role/page', { params });

// 添加角色
export const RoleAdd = (params: any) => requestClient.post('/role/add', params);

// 更新角色
export const RoleUpdate = (params: any) =>
  requestClient.post('/role/update', params);

// 删除角色
export const RoleRemove = (params: any) =>
  requestClient.post('/role/remove', params);

// 获取角色菜单
export const AuthorityMenu = (params: any) =>
  requestClient.get('/authority/menu', { params });

// 获取角色权限
export const AuthorityRole = (params: any) =>
  requestClient.get('/authority/role', { params });

// 添加权限按钮
export const ActionAdd = (params: any) =>
  requestClient.post('/action/add', params);

//  编辑角色权限
export const roleGrant = (params: any) =>
  requestClient.post('/authority/role/grant', params);
